<?php
class Joc
{
	
	public $dessarollador=array();
	public $distribuidor=array();
	public $plataforma=array();
	private $bd;
	
	public function __construct(){
		$bd = new BaseDatos();
	}
	
	public function afegirDesarollador(){
		$sql="";
		$command=$bd->prepare($sql);
		$command=$command->execute();
		$row=$command->rowCount();
		if ( $row <= "0" ) return "Error";
		else return $row;
	}
	
	public function afegirDistribuidor(){
		$sql="";
		$command=$bd->prepare($sql);
		$command=$command->execute();
		$row=$command->rowCount();
		if ( $row <= "0" ) return "Error";
		else return $row;
	}
	
	public function afegirPlataforma(){
		$sql="";
		$command=$bd->prepare($sql);
		$command=$command->execute();
		$row=$command->rowCount();
		if ( $row <= "0" ) return "Error";
		else return $row;
	}
	
	public function afegirJoc(){
		$sql="";
		$command=$bd->prepare($sql);
		$command=$command->execute();
		$row=$command->rowCount();
		if ( $row <= "0" ) return "Error";
		else return $row;
	}
	
	public function mostrarJoc(){
		$sql="";
		$command=$bd->prepare($sql);
		$command=$command->execute();
		$row=$command->rowCount();
		if ( $row < "0" || $row > "1" ) return "Error";
		else return $command->fetch(PDO::FETCH_ASSOC);
	}
}
?>